Carbon


GetThreadState

Header: Threads.h Carbon status: Supported

Obtains the state of a thread.

OSErr GetThreadState (
    ThreadID threadToGet, 
    ThreadState *threadState
);
Parameter descriptions
threadToGet

The thread ID of the thread about which you want information.

threadState

On return, a pointer to the state of the thread specified by threadToGet.

function result

A result code. Δ

DISCUSSION

A thread can be in one of three states: ready to execute (kThreadReadyState), stopped (kStoppedThreadState), or executing (kRunningThreadState).

To change the state of a specified thread, use SetThreadState.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)